package com.jinrustar.shenjiying.core.support

import android.app.Activity
import android.os.Bundle
import butterknife.ButterKnife


/**
 * Created by wei on 17-12-14.
 */
abstract class BaseActivity : Activity() {
    protected var TAG = this.javaClass.simpleName

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        onBeforeGetContentViewId()
        setContentView(getContentViewId())
        ButterKnife.bind(this)
        initAllMembersView(savedInstanceState)
    }


    open fun onBeforeGetContentViewId() {

    }

    abstract fun getContentViewId(): Int

    protected abstract fun initAllMembersView(savedInstanceState: Bundle?)

    override fun onDestroy() {
        super.onDestroy()
    }

}